# Presented By ZhaoEnxing
# time: 2021/10/15 14:10
#制作正态分布N(10,2)和 N(12,3)的概率密度函数图。

import numpy as np
import matplotlib.mlab as mlab
import matplotlib.pyplot as plt


def demo1():
    mu, sigma = 10, 2
    sampleNo = 10000
    np.random.seed(0)
    s = np.random.normal(mu, sigma, sampleNo)

    plt.hist(s, bins=100, density=True)
    plt.show()


def demo2():
    mu, sigma = 12, 3
    sampleNo = 10000
    np.random.seed(0)
    s = np.random.normal(mu, sigma, sampleNo)

    plt.hist(s, bins=100, density=True)
    plt.show()


demo1()
demo2()
